<!DOCTYPE html>
<html lang="zh_CN">
<head>
    <meta charset="UTF-8">
    <title>Add bootstrap to Thymeleaf</title>
    <link th:href="@{/css/bootstrap5.3.2.min.css}" rel="stylesheet">
</head>
<body>
<div class="container">
    <div class="row">
        <div class="col-md-6">
            <table class="table table-responsive table-bordered .table-striped">
                <thead>
                <tr>
                    <th> User Name</th>
                    <th> Email</th>
                </tr>
                </thead>
                <tbody>
                <tr th:each="user: ${users}">
                    <td th:text="${user.userName}"></td>
                    <td th:text="${user.email}"></td>
                    <td><a class="btn btn-primary" th:if="${user.role}=='ADMIN'">Update</a>
                        <a class="btn btn-danger" th:if="${user.role}=='ADMIN'">Delete</a>
                        <a class="btn btn-primary" th:unless="${user.role}=='ADMIN'">View</a>
                    </td>
                </tr>
                </tbody>
            </table>
        </div>
    </div>
</div>
</body>
</html>